import * as crytoJs from 'crypto-js'


export class Bcrypt {

  static async hash(str: string) {
    return crytoJs.SHA256(str).toString()
  }

  static async compireStringToHash(str: string, hashStr: string) {
    return crytoJs.SHA256(str).toString() === hashStr;
  }
}